<?php

namespace app\models;

use Yii;

/**
 * This is the model class for table "t_base_class_member".
 *
 * @property string $id
 * @property string $user_id 用户ID
 * @property string $class_id 班级ID
 * @property string $status 状态(申请加入/已缴费/正式成员/离开)
 * @property string $apply_time 申请时间
 * @property string $join_time 成为正式成员时间
 * @property string $leave_time 离开时间
 * @property int $del_flag 删除标识
 */
class TBaseClassMember extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 't_base_class_member';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['id'], 'required'],
            [['apply_time', 'join_time', 'leave_time'], 'safe'],
            [['del_flag'], 'integer'],
            [['id', 'user_id', 'class_id'], 'string', 'max' => 36],
            [['status'], 'string', 'max' => 64],
            [['id'], 'unique'],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'user_id' => 'User ID',
            'class_id' => 'Class ID',
            'status' => 'Status',
            'apply_time' => 'Apply Time',
            'join_time' => 'Join Time',
            'leave_time' => 'Leave Time',
            'del_flag' => 'Del Flag',
        ];
    }
}
